use super::*;

mod charset;
mod dict;
mod dict_private;
mod dict_top;
mod encoding;
mod error;
mod index;
mod outline;
mod std_names;

pub use charset::*;
pub use dict::*;
pub use dict_private::*;
pub use dict_top::*;
pub use encoding::*;
pub use error::*;
pub use index::*;
pub use outline::*;
pub use std_names::*;

pub type Card8 = u8;
pub type Card16 = u16;
pub type SID = u16;

const MAX_OPERANDS_LEN: usize = 48;

/// Enumerates Charset IDs defined in the Adobe Technical Note #5176, Table 22
pub mod charset_id {
	pub const ISO_ADOBE: usize = 0;
	pub const EXPERT: usize = 1;
	pub const EXPERT_SUBSET: usize = 2;
}
/// Enumerates Charset IDs defined in the Adobe Technical Note #5176, Table 16
pub mod encoding_id {
	pub const STANDARD: usize = 0;
	pub const EXPERT: usize = 1;
}

/// A type-safe wrapper for string ID.
#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Debug)]
pub struct StringId(pub u16);
impl FromData for StringId {
	const SIZE: usize = 2;
	#[inline]
	fn parse(data: &[u8]) -> Option<Self> {
		u16::parse(data).map(StringId)
	}
}
